Type Inference in Prolog: A New Approach

نویسندگان

  • Marc-Michel Corsini
  • Kaninda Musumbu
چکیده

Corsini, M.-M. and K. Musumbu, Type inference in Prolog: a new approach, Theoretical Computer Science 119 (1993) 23-38. This paper presents a new approach to type inference of Prolog programs. The novelty is in the fact that we only require the existence of a trpe domain 9 with a few primitive operations such as the abstract unification of elements of 3, and operations allowing the construction and the extraction of types. We focus on the derivation of accurate sharing information that we prove correct. The derivation process is designed as an application of a recent method for global analysis for logic programs, formalized by an abstract interpretation framework. The framework ensures correctness and termination of the inferred properties if certain requirements are satisfied.

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

منابع مشابه

Type Inference in Prolog and Its Application

In this paper we present a type inference method for Prolog programs. The new idea is to describe a superset of the success set by associating a type substitution (an assignment of sets of ground terms to variables) with each head of definite clause. This approach not only conforms to the style of definition inherent to Prolog but also gives some accuracy to the types infered. We show the basic...

متن کامل

Typed Prolog: A Semantic Reconstruction of the Mycroft-O'Keefe Type System

Mycroft and O'Keefe 25] presented a declaration-based type system for Pro-log. However, they did not clarify the semantics of the type system, leading to several criticisms being voiced against it. We propose that the language accepted by this type system be viewed as a typed variant of Prolog, called Typed Prolog. We deene the formal semantics of Typed Prolog along the lines of many-sorted log...

متن کامل

Prolog implementation of type inference algorithms for mobile ambients

The type system for the ambient calculus M [2] is presented in a new form that derives the minimal type of a term in the minimal environment, and is therefore more amenable than the original form to a translation into a type inference algorithm. From the new formulation a Prolog program is derived, which implements the same type inference algorithm for M that was defined through formal rules in...

متن کامل

Type Inference for Mobile Ambients in Prolog

The type system for the ambient calculus M3 [8] is presented in a new form that derives the type of a term with the minimal set of mobility assumptions, and is therefore more amenable than the original form to a translation into a type inference algorithm. From the new formulation a Prolog program is derived, which implements a type inference algorithm for M3 analogous to the one previously spe...

متن کامل

Type Inference for Programming Languages: A Constraint Logic Programming Approach

In this paper we present an application of Constraint Logic Programming to the design and implementation of type inference algorithms for programming languages. We present implementations in Prolog and Constraint Handling Rules (CHR) of several algorithms which belong to the state of the art of type inference for programming languages: the Damas-Milner type system, the Ohory system for labeled ...

متن کامل

ذخیره در منابع من


  با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

عنوان ژورنال:
  • Theor. Comput. Sci.

دوره 119  شماره 

صفحات  -

تاریخ انتشار 1993